--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
Commit db2ad8a7a7cdabb4a9f6a1909226e8e04788ddb7
Parents : 22b54b3
Author : Mark Qvist <mark@unsigned.io>
Date : 2022-11-22T19:46:14+01:00
Added file provider configuration
Changes
3 files changed, 17 insertions(+), 0 deletions(-)
Diff
diff --git a/sbapp/Makefile b/sbapp/Makefile
index 72b91aaf..18ba2a38 100644
--- a/sbapp/Makefile
+++ b/sbapp/Makefile
@@ -34,6 +34,7 @@ injectxml:
mkdir -p .buildozer/android/platform/build-arm64-v8a_armeabi-v7a/dists/sideband/src/main/res/xml
mkdir -p .buildozer/android/platform/build-arm64-v8a_armeabi-v7a/dists/sideband/templates
cp patches/device_filter.xml .buildozer/android/platform/build-arm64-v8a_armeabi-v7a/dists/sideband/src/main/res/xml/
+ cp patches/file_paths.xml .buildozer/android/platform/build-arm64-v8a_armeabi-v7a/dists/sideband/src/main/res/xml/
cp patches/AndroidManifest.tmpl.xml .buildozer/android/platform/build-arm64-v8a_armeabi-v7a/dists/sideband/templates/
debug:
diff --git a/sbapp/patches/AndroidManifest.tmpl.xml b/sbapp/patches/AndroidManifest.tmpl.xml
index e17a732a..cf24d44e 100644
--- a/sbapp/patches/AndroidManifest.tmpl.xml
+++ b/sbapp/patches/AndroidManifest.tmpl.xml
@@ -142,6 +142,18 @@
{% for a in args.add_activity %}
<activity android:name="{{ a }}"></activity>
{% endfor %}
+
+ <provider
+ android:name="android.support.v4.content.FileProvider"
+ android:authorities="io.unsigned.sideband.provider"
+ android:exported="false"
+ android:grantUriPermissions="true">
+ <!-- ressource file to create -->
+ <meta-data
+ android:name="android.support.FILE_PROVIDER_PATHS"
+ android:resource="@xml/file_paths">
+ </meta-data>
+ </provider>
</application>
</manifest>
diff --git a/sbapp/patches/file_paths.xml b/sbapp/patches/file_paths.xml
new file mode 100644
index 00000000..7d3c7d50
--- /dev/null
+++ b/sbapp/patches/file_paths.xml
@@ -0,0 +1,4 @@
+<?xml version="1.0" encoding="utf-8"?>
+<paths xmlns:android="http://schemas.android.com/apk/res/android">
+ <files-path name="exports" path="exports/"/>
+</paths>
\ No newline at end of file
──────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────